package com.cd2cd.code_template.configuration.exceptions;

import org.springframework.http.HttpStatus;

import com.cd2cd.code_template.configuration.constants.ServiceCode;

/**
 * 500
 */
public class ServerInternalErrorException extends BaseRuntimeException {

	private static final long serialVersionUID = 1L;

	public ServerInternalErrorException(ServiceCode serviceCode, String message, Throwable cause) {
		super(serviceCode, message, cause);
		this.httpStatus = HttpStatus.INTERNAL_SERVER_ERROR;
	}

	public ServerInternalErrorException(ServiceCode serviceCode, Throwable cause) {
		super(serviceCode, serviceCode.msg, cause);
		this.httpStatus = HttpStatus.INTERNAL_SERVER_ERROR;
	}

	public ServerInternalErrorException(ServiceCode serviceCode, String msg) {
		super(serviceCode, msg);
		this.httpStatus = HttpStatus.INTERNAL_SERVER_ERROR;
	}
}
